@extends('layouts.admin')
@section('content')
    <script type="application/javascript" src="{{url()}}/js/table.js"></script>
    <div class="modal-msg"></div>
    <?php
    $array = $entity->getProperties();
    $keys = array_keys($array);
    ?>
    <form action="" method="POST" class="form-edit-entity">
        <input hidden name="table" value="{{ $table }}">
        @foreach($keys as $key)
            @if($key != 'Timestamp')
                <div class="form-group">
                    <div class="row">
                        <div class="col-md-2">
                            <label>{{$key}}</label>
                        </div>
                        <div class="col-md-6"><input required="required" type="text" name="{{$key}}"
                                                     value="{!!  $array[$key]->getValue()!!}"
                                                     class="form-control partition-name"
                                                     @if($key == 'PartitionKey') readonly @endif
                                                     @if($key == 'RowKey') readonly @endif>
                        </div>
                    </div>
                </div>
            @endif
        @endforeach
        <div class="form-group">
            <div class="row">

              <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1">
                  <input type="submit" class="btn btn-primary btn-md" value="Save"/>
              </div>
                <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 loading">
                    <img src="{{url()}}/img/loading_spinner.gif">
                </div>
            </div>
        </div>
    </form>
@endsection